﻿using System;
using ebc.message.contract;
using ebc.worker.contract;

namespace ebc.worker {
    public class Worker : IWorker {

        public void ProcessWorkerRequest(WorkerRequest request) {
            var result = request.FromSource + "=>InputRequest Worker\t<=WorkerRequest=>" + Environment.NewLine +
                "=>OutputRequest Worker\t<=WorkerResult=>" + Environment.NewLine;
            OnWorkerResult(new WorkerResult { FromTarget = result });
        }

        public event Action<WorkerResult> OnWorkerResult;

    }
}
